﻿<%@ Page Title="Log In" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true"
    CodeBehind="Login.aspx.cs" Inherits="MyHealthOnline.Account.Login" %>
<%@ Register Assembly="SD.LLBLGen.Pro.ORMSupportClasses.NET20" Namespace="SD.LLBLGen.Pro.ORMSupportClasses"
    TagPrefix="llblgenpro" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %>
<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">
</asp:Content>
<asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent">

<ajaxToolkit:ToolkitScriptManager runat="Server" EnableScriptGlobalization="true"
                                       EnableScriptLocalization="true" ID="ScriptManager1" /> 

    <h2>
        Log In
    </h2>
     <p>
        Please enter your username and password.
        <asp:HyperLink ID="RegisterHyperLink" runat="server" EnableViewState="false">Register</asp:HyperLink> if you don't have an account.
    </p>
    <%--<p>
                        <asp:Label ID="UserRoleLabel" Font-Size="Medium" runat="server" AssociatedControlID="userRoleDropDownList">Rol: &nbsp</asp:Label>
                        <asp:DropDownList ID="userRoleDropDownList" runat="server" Width="124px" DataTextFormatString="True"
                         DataTextField="Rol" AutoPostBack="true">
                            <asp:ListItem Value="-1">Selected Option</asp:ListItem>
                            <asp:ListItem>Pacient</asp:ListItem>
                            <asp:ListItem>Specialist</asp:ListItem>
                            <asp:ListItem>Administrator</asp:ListItem>
                        </asp:DropDownList>
                        <asp:RequiredFieldValidator ID="dropDownList_Validator" runat="server" 
                                ErrorMessage="RequiredFieldValidator" ControlToValidate="userRoleDropDownList" CssClass="failureNotification"
                                display="Dynamic" InitialValue="-1" ValidationGroup="LoginUser" SetFocusOnError="true">*
                        </asp:RequiredFieldValidator>

                    </p>--%>
   
     <asp:Login ID="LoginUser" runat="server" VisibleWhenLoggedIn="False" 
        TitleText="" OnAuthenticate="Login1_Authenticate" BackColor="#EFF3FB" 
        BorderColor="#B5C7DE" BorderPadding="4" BorderStyle="Solid" BorderWidth="1px" 
        Font-Names="Verdana" Font-Size="0.8em" ForeColor="#333333">
         <InstructionTextStyle Font-Italic="True" ForeColor="Black" />
         <LayoutTemplate>
             <table cellpadding="1" cellspacing="0" style="border-collapse:collapse;">
                 <tr>
                     <td>
                         <table cellpadding="0">
                             <tr>
                    <td><asp:Label ID="UserRoleLabel" runat="server" AssociatedControlID="userRoleDropDownList">Rol: &nbsp</asp:Label></td>
                    <td> <asp:DropDownList ID="userRoleDropDownList" runat="server" Width="124px" DataTextFormatString="True"
                         DataTextField="Rol" AutoPostBack="true">
                            <asp:ListItem Value="-1">Selected Option</asp:ListItem>
                            <asp:ListItem>Patient</asp:ListItem>
                            <asp:ListItem>Specialist</asp:ListItem>
                            <asp:ListItem>Administrator</asp:ListItem>
                        </asp:DropDownList>
                        <asp:RequiredFieldValidator ID="dropDownList_Validator" runat="server" 
                                ErrorMessage="RequiredFieldValidator" ControlToValidate="userRoleDropDownList"
                                display="Dynamic" InitialValue="-1" ValidationGroup="LoginUser" >*
                        </asp:RequiredFieldValidator></td>
                </tr>
                             <tr>
                                 <td align="right">
                                     <asp:Label ID="UserNameLabel" runat="server" AssociatedControlID="UserName">User Name:</asp:Label>
                                 </td>
                                 <td>
                                     <asp:TextBox ID="UserName" runat="server"></asp:TextBox>
                                     <asp:RequiredFieldValidator ID="UserNameRequired" runat="server" 
                                         ControlToValidate="UserName" ErrorMessage="User Name is required." 
                                         ToolTip="User Name is required." ValidationGroup="LoginUser">*</asp:RequiredFieldValidator>
                                 </td>
                             </tr>
                             <tr>
                                 <td align="right">
                                     <asp:Label ID="PasswordLabel" runat="server" AssociatedControlID="Password">Password:</asp:Label>
                                 </td>
                                 <td>
                                     <asp:TextBox ID="Password" runat="server" TextMode="Password"></asp:TextBox>
                                     <asp:RequiredFieldValidator ID="PasswordRequired" runat="server" 
                                         ControlToValidate="Password" ErrorMessage="Password is required." 
                                         ToolTip="Password is required." ValidationGroup="LoginUser">*</asp:RequiredFieldValidator>
                                 </td>
                             </tr>
                             <tr>
                                 <td colspan="2">
                                     <asp:CheckBox ID="RememberMe" runat="server" Text="Remember me next time." />
                                 </td>
                             </tr>
                             <tr>
                                 <td align="center" colspan="2" style="color:Red;">
                                     <asp:Literal ID="FailureText" runat="server" EnableViewState="False"></asp:Literal>
                                 </td>
                             </tr>
                             <tr>
                                 <td align="right" colspan="2">
                                     <asp:Button ID="LoginButton" runat="server" CommandName="Login" Text="Log In" 
                                         ValidationGroup="LoginUser" />
                                 </td>
                             </tr>
                         </table>
                     </td>
                 </tr>
             </table>
         </LayoutTemplate>
         <LoginButtonStyle BackColor="White" BorderColor="#507CD1" BorderStyle="Solid" 
             BorderWidth="1px" Font-Names="Verdana" Font-Size="0.8em" ForeColor="#284E98" />
         <TextBoxStyle Font-Size="0.8em" />
         <TitleTextStyle BackColor="#507CD1" Font-Bold="True" Font-Size="0.9em" 
             ForeColor="White" />
     </asp:Login>
   








   <%-- <asp:Login ID="LoginUser" runat="server" EnableViewState="false" RenderOuterTable="false">
        <LayoutTemplate>
            <span class="failureNotification">
                <asp:Literal ID="FailureText" runat="server"></asp:Literal>
            </span>
            <asp:ValidationSummary ID="LoginUserValidationSummary" runat="server" CssClass="failureNotification" 
                 ValidationGroup="LoginUserValidationGroup"/>
            <div class="accountInfo">
                <fieldset class="login">
                    <legend>Account Information</legend>
                    <p>
                        <asp:Label ID="UserNameLabel" runat="server" AssociatedControlID="UserName">Username:</asp:Label>
                        <asp:TextBox ID="UserName" runat="server" CssClass="textEntry"></asp:TextBox>
                        <asp:RequiredFieldValidator ID="UserNameRequired" runat="server" ControlToValidate="UserName" 
                             CssClass="failureNotification" ErrorMessage="User Name is required." ToolTip="User Name is required." 
                             ValidationGroup="LoginUserValidationGroup">*</asp:RequiredFieldValidator>
                    </p>
                    <p>
                        <asp:Label ID="PasswordLabel" runat="server" AssociatedControlID="Password">Password:</asp:Label>
                        <asp:TextBox ID="Password" runat="server" CssClass="passwordEntry" TextMode="Password"></asp:TextBox>
                        <asp:RequiredFieldValidator ID="PasswordRequired" runat="server" ControlToValidate="Password" 
                             CssClass="failureNotification" ErrorMessage="Password is required." ToolTip="Password is required." 
                             ValidationGroup="LoginUserValidationGroup">*</asp:RequiredFieldValidator>
                    </p>
                    <p>
                        <asp:CheckBox ID="RememberMe" runat="server"/>
                        <asp:Label ID="RememberMeLabel" runat="server" AssociatedControlID="RememberMe" CssClass="inline">Keep me logged in</asp:Label>
                    </p>
                </fieldset>
                <p class="submitButton">
                    <asp:Button ID="LoginButton" runat="server" CommandName="Login" Text="Log In" ValidationGroup="LoginUserValidationGroup"/>
                </p>
            </div>
        </LayoutTemplate>
    </asp:Login>--%>
</asp:Content>
